/*
 * @Author: czy
 * @Date: 2021-05-21 14:29:21
 * @LastEditTime: 2021-07-12 21:55:28
 */
#include "datetime.h"

#include "sys/system.h"

static time_t timestamp = 0;

/**
 * @description: Get timestamp.
 * @param time  Timestamp pointer.
 */
void gettime(time_t *time)
{
    *time = timestamp;
}

/**
 * @description: Set timestamp.
 * @param time  Timestamp pointer.
 */
void settime(time_t *time)
{
    timestamp = *time;
}